<template>
  <div id="takebacklist"> 


          <el-table :data="datalist" style="width: 100%" :height="dtheight" :header-cell-style="{background:'#4F81BC',color:'white'}"
           :row-class-name="tableRowClassName"  :border="true">

               
                <el-table-column label="用户名"  align='center' >                   
                    <template slot-scope="scope">                   
                        <span >{{ scope.row.nickname }}</span>
                    </template>
                </el-table-column>
                <el-table-column label="手机号"  align='center' >                   
                    <template slot-scope="scope">                   
                        <span >{{ scope.row.telphone }}</span>
                    </template>
                </el-table-column>
                <el-table-column label="团队长"  align='center' >                   
                    <template slot-scope="scope">                   
                        <span v-if="scope.row.leader">{{ scope.row.leader.nickname }}</span>
                    </template>
                </el-table-column>
                <el-table-column label="金蜜券数量"  align='center' >                   
                    <template slot-scope="scope">                   
                        <span >{{ scope.row.gdbticket }}</span>
                    </template>
                </el-table-column>
                <el-table-column label="总产出"  align='center' >                   
                    <template slot-scope="scope">                   
                        <span >{{ scope.row.produced_num }}</span>
                    </template>
                </el-table-column>
                <el-table-column label="总消耗"  align='center' >                   
                    <template slot-scope="scope">                   
                        <span >{{ scope.row.consume_num }}</span>
                    </template>
                </el-table-column>
                <el-table-column label="差额"  align='center' >                   
                    <template slot-scope="scope">                   
                        <span >{{ scope.row.disparity }}</span>
                    </template>
                </el-table-column>

                  <el-table-column label="操作" align='center' width="300px"  fixed="right">
                    <template slot-scope="scope">                  
                        <el-button size="mini"  type="primary"  plain class="button_class2" @click="go_but1(scope.row)">收货蜂巢</el-button>
                        <el-button size="mini"  type="primary"  plain class="button_class1" @click="go_but2(scope.row)">金蜜券调控</el-button> 
                    </template>
                </el-table-column>
               
            </el-table>  

   </div>
</template>

<script>

export default {
   name: 'takebacklist',
   props:{
      datalist:{  
        //type:Array,
       default:()=>[]
     },
  },
  data () {
    return {
        dtheight:'500',  //窗口高度

        

    }
  },
   components:{

  },
  created(){
     this.dtheight = window.innerHeight - 295
      
  },
  mounted (){
    
  },
  methods: {

      go_but1(row){
          this.$router.push({
          path: '/index/reorder',
          query: {
            name:row.telphone,
            id:row.uid,
          }
        })
      },
      go_but2(row){
          this.$router.push({
          path: '/index/jdcoupons',
          query: {
            name:row.telphone,
            id:row.uid,
          }
        })
      },
 
 

  }
}
</script>


<style scoped>

</style>